        {include file="public/header"}
		<script type="text/javascript" src="http://api.map.baidu.com/api?v=2.0&ak=5cc1ae75a01f2047077898c7e43d6bd8"></script>
		<div id="allmap" style="width:100%;height:450px;"></div>
    	<div class="tplay-body" style="padding:20px;">
	        <form class="layui-form" id="tplay-login">
			  <div class="layui-form-item">
			      <input type="text" name="name" lay-verify="required" placeholder="称呼" autocomplete="off" class="layui-input">
			  </div>
			  <div class="layui-form-item">
			      <input type="text" name="phone" lay-verify="required" placeholder="电话" autocomplete="off" class="layui-input">
			  </div>
              <div class="layui-form-item">
                  <input type="text" name="email" lay-verify="required" placeholder="邮箱" autocomplete="off" class="layui-input">
              </div>
			  <div class="layui-form-item">
                  <textarea name="content" placeholder="请输入内容" class="layui-textarea"></textarea>
			  </div>
			  <button class="layui-btn layui-btn-sm layui-btn-normal" lay-submit lay-filter="tplay-login-submit" id="tplay-login-submit">立即提交</button>
              <button type="reset" class="layui-btn layui-btn-primary layui-btn-sm">重置</button>
			</form>
		</div>
		{include file="public/footer"}
		<script type="text/javascript">
		    layui.use(['form'], function () {
		        var form = layui.form,$ = layui.$,apiconfig = layui.apiconfig;
		        form.on('submit(tplay-login-submit)', function(data) {
                    $.ajax({
                        url:"/index/contact/contact",
                        data:$('#tplay-login').serialize(),
                        type:'post',
                        async: false,
                        success:function(res) {
                            layer.tips(res.msg,'#tplay-login-submit');
                            if(res.code == 1) {
                                $("#tplay-login")[0].reset()
                            }
                        }
                    })
                    return false;
                });
		    });
          
          // 百度地图API功能
          var map = new BMap.Map("allmap");    // 创建Map实例
          map.centerAndZoom(new BMap.Point(116.404, 39.915), 12);  // 初始化地图,设置中心点坐标和地图级别
          //添加地图类型控件
          map.addControl(new BMap.MapTypeControl({
              mapTypes:[
                  BMAP_NORMAL_MAP,
                  BMAP_HYBRID_MAP
              ]}));	  
          map.setCurrentCity("北京");          // 设置地图显示的城市 此项是必须设置的
          map.enableScrollWheelZoom(true);     //开启鼠标滚轮缩放
		</script>